projects
/
project
/
bcm63xx
/
u-boot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
eef0b8a
)
net: phy: dp83867: switch to use phy_get_ofnode()
author
Grygorii Strashko
<
[email protected]
>
Thu, 5 Jul 2018 17:02:49 +0000
(12:02 -0500)
committer
Joe Hershberger
<
[email protected]
>
Thu, 26 Jul 2018 19:08:22 +0000
(14:08 -0500)
Use PHY API phy_get_ofnode() helper to get PHY DT node.
Signed-off-by: Grygorii Strashko <
[email protected]
>
Acked-by: Joe Hershberger <
[email protected]
>
Tested-by: Siva Durga Prasad Paladugu <
[email protected]
>
drivers/net/phy/ti.c
patch
|
blob
|
history
diff --git
a/drivers/net/phy/ti.c
b/drivers/net/phy/ti.c
index 655f46d22f9b3ff05041f1f42b08643d65d06b9b..f870e6d66206ec52e976d03d956b7667faea5470 100644
(file)
--- a/
drivers/net/phy/ti.c
+++ b/
drivers/net/phy/ti.c
@@
-172,8
+172,11
@@
void phy_write_mmd_indirect(struct phy_device *phydev, int prtad,
static int dp83867_of_init(struct phy_device *phydev)
{
struct dp83867_private *dp83867 = phydev->priv;
- struct udevice *dev = phydev->dev;
- ofnode node = dev_ofnode(dev);
+ ofnode node;
+
+ node = phy_get_ofnode(phydev);
+ if (!ofnode_valid(node))
+ return -EINVAL;
if (ofnode_read_bool(node, "ti,max-output-impedance"))
dp83867->io_impedance = DP83867_IO_MUX_CFG_IO_IMPEDANCE_MAX;